﻿<UserControl
    x:Class="Google_Plus.Types.LightBox"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:controls="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone.Controls"
    xmlns:imageTools="clr-namespace:ImageTools.Controls;assembly=ImageTools.Controls" 
    xmlns:local="clr-namespace:Google_Plus.Types"
    mc:Ignorable="d"
    FontFamily="{StaticResource PhoneFontFamilyNormal}"
    FontSize="{StaticResource PhoneFontSizeNormal}"
    Foreground="{StaticResource PhoneForegroundBrush}"
    Loaded="UserControl_Loaded"
    Tap="UserControl_Tap"
    d:DesignHeight="480" d:DesignWidth="480">

    <StackPanel>
        <controls:Pivot 
            x:Name="SlideBox"
            SelectionChanged="Pivot_SelectionChanged" 
            Style="{StaticResource PivotWithoutHeader}">
            <controls:PivotItem Header="Image1" Margin="0">
                <imageTools:AnimatedImage x:Name="Image1"/>
            </controls:PivotItem>

            <controls:PivotItem Header="Image2" Margin="0">
                <imageTools:AnimatedImage x:Name="Image2"/>
            </controls:PivotItem>

            <controls:PivotItem Header="Image3" Margin="0">
                <imageTools:AnimatedImage x:Name="Image3"/>
            </controls:PivotItem>
        </controls:Pivot>

        <ListBox 
            x:Name="ImageList"
            ItemsSource="{Binding}"
            ScrollViewer.HorizontalScrollBarVisibility="Auto"
            ScrollViewer.VerticalScrollBarVisibility="Disabled">
            <ListBox.ItemsPanel>
                <ItemsPanelTemplate>
                    <StackPanel Orientation="Horizontal"/>
                </ItemsPanelTemplate>
            </ListBox.ItemsPanel>
            <ListBox.ItemTemplate>
                <DataTemplate>
                    <local:HighlightAnimatedImage
                        DataContext="{Binding}"
                        Tap="HighlightAnimatedImage_Tap"/>
                </DataTemplate>
            </ListBox.ItemTemplate>
        </ListBox>
    </StackPanel>
</UserControl>
